{
  pkgs,
  ...
}:

{
  programs.fish.shellInitLast = "pixi completion --shell fish | source";

  home.packages = with pkgs; [ pixi ];

  home.file.pixi-config = {
    target = ".pixi/config.toml";
    text = ''
      default-channels = [ "conda-forge" ]
      shell.change-ps1 = true
      tls-no-verify = false

      [mirrors]
      "https://conda.anaconda.org/conda-forge" = [
          "https://mirrors.ustc.edu.cn/anaconda/cloud/conda-forge/",
          "https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud",
          "http://mirrors.aliyun.com/anaconda/cloud",
          "https://mirror.sjtu.edu.cn/anaconda/cloud",
      ]

      "https://conda.anaconda.org/bioconda" = [
          "https://mirrors.ustc.edu.cn/anaconda/cloud/bioconda/",
          "https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud",
          "http://mirrors.aliyun.com/anaconda/cloud",
      ]

      [repodata-config]
      disable-jlap = true
      disable-bzip2 = true
      disable-zstd = false

      [pypi-config]
      index-url = "https://mirrors.ustc.edu.cn/pypi/simple"
      extra-index-urls = [
        "https://mirrors.aliyun.com/pypi/simple/",
        "https://pypi.tuna.tsinghua.edu.cn/simple",
        "http://mirrors.cloud.tencent.com/pypi/simple",
      ]
      keyring-provider = "subprocess"
    '';
  };
}
